using System;
using System.Collections;
using System.Collections.Generic;

using Atom.Data.Base;

namespace Atom.Data.BusinessObjects
{
    public partial class HLeavehosRecord : BusinessBase<string>
    {
        #region Declarations

        private string _inhosid = String.Empty;
        private int _currentinhosmark = default(Int32);
        private string _diagnoseid = null;
        private string _caseid = null;
        private string _feetypeid = null;
        private string _sicktypeid = null;
        private string _enterhosofficeid = null;
        private string _linkman = null;
        private string _relation = null;
        private string _inhosofficeid = null;
        private string _address = null;
        private string _relationpostcode = null;
        private System.DateTime _enterhosdate = new DateTime();
        private string _linkmode = null;
        private string _relationtelephone = null;
        private string _chargedoctorid = null;
        private string _enterhosdiagnoseid = null;
        private string _entermode = null;
        private System.DateTime? _enterofficedate = null;
        private string _officebedid = null;
        private System.DateTime _beddate = new DateTime();
        private decimal? _advancemoney = null;
        private string _inhostrack = String.Empty;
        private decimal _totalconsumemoney = default(Decimal);
        private decimal _balancemoney = default(Decimal);
        private string _clinicdoctorid = null;
        private string _introducer = null;
        private decimal _afterabatemoeny = default(Decimal);
        private string _cautionerid = null;
        private string _inhospurposeid = null;
        private int _inhostimes = default(Int32);
        private int _inhosstate = default(Int32);
        private string _motherid = null;
        private int _age = default(Int32);
        private string _ageunit = null;
        private string _enterhosoperatorid = null;
        private string _leavehosdiagnoseid = null;
        private string _leavehosmode = null;
        private System.DateTime _enterhostransactdate = new DateTime();
        private System.DateTime _leavehosdate = new DateTime();
        private string _mark = null;
        private int _inhosdays = default(Int32);
        private string _leavehosoperatorid = null;
        private System.DateTime _leavehostransactdate = new DateTime();
        private string _tendlevel = null;

       

     

      

        #endregion

        #region Constructors

        public HLeavehosRecord() { }

        #endregion

        #region Methods

        public override int GetHashCode()
        {
            System.Text.StringBuilder sb = new System.Text.StringBuilder();

            sb.Append(this.GetType().FullName);
            sb.Append(_inhosid);
            sb.Append(_currentinhosmark);
            sb.Append(_diagnoseid);
            sb.Append(_caseid);
            sb.Append(_feetypeid);
            sb.Append(_sicktypeid);
            sb.Append(_enterhosofficeid);
            sb.Append(_linkman);
            sb.Append(_relation);
            sb.Append(_inhosofficeid);
            sb.Append(_address);
            sb.Append(_relationpostcode);
            sb.Append(_enterhosdate);
            sb.Append(_linkmode);
            sb.Append(_relationtelephone);
            sb.Append(_chargedoctorid);
            sb.Append(_enterhosdiagnoseid);
            sb.Append(_entermode);
            sb.Append(_enterofficedate);
            sb.Append(_officebedid);
            sb.Append(_beddate);
            sb.Append(_advancemoney);
            sb.Append(_inhostrack);
            sb.Append(_totalconsumemoney);
            sb.Append(_balancemoney);
            sb.Append(_clinicdoctorid);
            sb.Append(_introducer);
            sb.Append(_afterabatemoeny);
            sb.Append(_cautionerid);
            sb.Append(_inhospurposeid);
            sb.Append(_inhostimes);
            sb.Append(_inhosstate);
            sb.Append(_motherid);
            sb.Append(_age);
            sb.Append(_ageunit);
            sb.Append(_enterhosoperatorid);
            sb.Append(_leavehosdiagnoseid);
            sb.Append(_leavehosmode);
            sb.Append(_enterhostransactdate);
            sb.Append(_leavehosdate);
            sb.Append(_mark);
            sb.Append(_inhosdays);
            sb.Append(_leavehosoperatorid);
            sb.Append(_leavehostransactdate);
            sb.Append(_tendlevel);

            return sb.ToString().GetHashCode();
        }

        #endregion

        #region Properties

        public override string Id
        {
            get
            {
                System.Text.StringBuilder uniqueId = new System.Text.StringBuilder();
                uniqueId.Append(_inhosid.ToString());
                uniqueId.Append("^");
                uniqueId.Append(_currentinhosmark.ToString());
                return uniqueId.ToString();
            }
        }

        public virtual string Inhosid
        {
            get { return _inhosid; }
            set
            {
                OnInhosidChanging();
                _inhosid = value;
                OnInhosidChanged();
            }
        }
        partial void OnInhosidChanging();
        partial void OnInhosidChanged();

        public virtual int Currentinhosmark
        {
            get { return _currentinhosmark; }
            set
            {
                OnCurrentinhosmarkChanging();
                _currentinhosmark = value;
                OnCurrentinhosmarkChanged();
            }
        }
        partial void OnCurrentinhosmarkChanging();
        partial void OnCurrentinhosmarkChanged();

        public virtual string Diagnoseid
        {
            get { return _diagnoseid; }
            set
            {
                OnDiagnoseidChanging();
                _diagnoseid = value;
                OnDiagnoseidChanged();
            }
        }
        partial void OnDiagnoseidChanging();
        partial void OnDiagnoseidChanged();

        public virtual string Caseid
        {
            get { return _caseid; }
            set
            {
                OnCaseidChanging();
                _caseid = value;
                OnCaseidChanged();
            }
        }
        partial void OnCaseidChanging();
        partial void OnCaseidChanged();

        public virtual string Feetypeid
        {
            get { return _feetypeid; }
            set
            {
                OnFeetypeidChanging();
                _feetypeid = value;
                OnFeetypeidChanged();
            }
        }
        partial void OnFeetypeidChanging();
        partial void OnFeetypeidChanged();

        public virtual string Sicktypeid
        {
            get { return _sicktypeid; }
            set
            {
                OnSicktypeidChanging();
                _sicktypeid = value;
                OnSicktypeidChanged();
            }
        }
        partial void OnSicktypeidChanging();
        partial void OnSicktypeidChanged();

        public virtual string Enterhosofficeid
        {
            get { return _enterhosofficeid; }
            set
            {
                OnEnterhosofficeidChanging();
                _enterhosofficeid = value;
                OnEnterhosofficeidChanged();
            }
        }
        partial void OnEnterhosofficeidChanging();
        partial void OnEnterhosofficeidChanged();

        public virtual string Linkman
        {
            get { return _linkman; }
            set
            {
                OnLinkmanChanging();
                _linkman = value;
                OnLinkmanChanged();
            }
        }
        partial void OnLinkmanChanging();
        partial void OnLinkmanChanged();

        public virtual string Relation
        {
            get { return _relation; }
            set
            {
                OnRelationChanging();
                _relation = value;
                OnRelationChanged();
            }
        }
        partial void OnRelationChanging();
        partial void OnRelationChanged();

        public virtual string Inhosofficeid
        {
            get { return _inhosofficeid; }
            set
            {
                OnInhosofficeidChanging();
                _inhosofficeid = value;
                OnInhosofficeidChanged();
            }
        }
        partial void OnInhosofficeidChanging();
        partial void OnInhosofficeidChanged();

        public virtual string Address
        {
            get { return _address; }
            set
            {
                OnAddressChanging();
                _address = value;
                OnAddressChanged();
            }
        }
        partial void OnAddressChanging();
        partial void OnAddressChanged();

        public virtual string Relationpostcode
        {
            get { return _relationpostcode; }
            set
            {
                OnRelationpostcodeChanging();
                _relationpostcode = value;
                OnRelationpostcodeChanged();
            }
        }
        partial void OnRelationpostcodeChanging();
        partial void OnRelationpostcodeChanged();

        public virtual System.DateTime Enterhosdate
        {
            get { return _enterhosdate; }
            set
            {
                OnEnterhosdateChanging();
                _enterhosdate = value;
                OnEnterhosdateChanged();
            }
        }
        partial void OnEnterhosdateChanging();
        partial void OnEnterhosdateChanged();

        public virtual string Linkmode
        {
            get { return _linkmode; }
            set
            {
                OnLinkmodeChanging();
                _linkmode = value;
                OnLinkmodeChanged();
            }
        }
        partial void OnLinkmodeChanging();
        partial void OnLinkmodeChanged();

        public virtual string Relationtelephone
        {
            get { return _relationtelephone; }
            set
            {
                OnRelationtelephoneChanging();
                _relationtelephone = value;
                OnRelationtelephoneChanged();
            }
        }
        partial void OnRelationtelephoneChanging();
        partial void OnRelationtelephoneChanged();

        public virtual string Chargedoctorid
        {
            get { return _chargedoctorid; }
            set
            {
                OnChargedoctoridChanging();
                _chargedoctorid = value;
                OnChargedoctoridChanged();
            }
        }
        partial void OnChargedoctoridChanging();
        partial void OnChargedoctoridChanged();

        public virtual string Enterhosdiagnoseid
        {
            get { return _enterhosdiagnoseid; }
            set
            {
                OnEnterhosdiagnoseidChanging();
                _enterhosdiagnoseid = value;
                OnEnterhosdiagnoseidChanged();
            }
        }
        partial void OnEnterhosdiagnoseidChanging();
        partial void OnEnterhosdiagnoseidChanged();

        public virtual string Entermode
        {
            get { return _entermode; }
            set
            {
                OnEntermodeChanging();
                _entermode = value;
                OnEntermodeChanged();
            }
        }
        partial void OnEntermodeChanging();
        partial void OnEntermodeChanged();

        public virtual System.DateTime? Enterofficedate
        {
            get { return _enterofficedate; }
            set
            {
                OnEnterofficedateChanging();
                _enterofficedate = value;
                OnEnterofficedateChanged();
            }
        }
        partial void OnEnterofficedateChanging();
        partial void OnEnterofficedateChanged();

        public virtual string Officebedid
        {
            get { return _officebedid; }
            set
            {
                OnOfficebedidChanging();
                _officebedid = value;
                OnOfficebedidChanged();
            }
        }
        partial void OnOfficebedidChanging();
        partial void OnOfficebedidChanged();

        public virtual System.DateTime Beddate
        {
            get { return _beddate; }
            set
            {
                OnBeddateChanging();
                _beddate = value;
                OnBeddateChanged();
            }
        }
        partial void OnBeddateChanging();
        partial void OnBeddateChanged();

        public virtual decimal? Advancemoney
        {
            get { return _advancemoney; }
            set
            {
                OnAdvancemoneyChanging();
                _advancemoney = value;
                OnAdvancemoneyChanged();
            }
        }
        partial void OnAdvancemoneyChanging();
        partial void OnAdvancemoneyChanged();

        public virtual string Inhostrack
        {
            get { return _inhostrack; }
            set
            {
                OnInhostrackChanging();
                _inhostrack = value;
                OnInhostrackChanged();
            }
        }
        partial void OnInhostrackChanging();
        partial void OnInhostrackChanged();

        public virtual decimal Totalconsumemoney
        {
            get { return _totalconsumemoney; }
            set
            {
                OnTotalconsumemoneyChanging();
                _totalconsumemoney = value;
                OnTotalconsumemoneyChanged();
            }
        }
        partial void OnTotalconsumemoneyChanging();
        partial void OnTotalconsumemoneyChanged();

        public virtual decimal Balancemoney
        {
            get { return _balancemoney; }
            set
            {
                OnBalancemoneyChanging();
                _balancemoney = value;
                OnBalancemoneyChanged();
            }
        }
        partial void OnBalancemoneyChanging();
        partial void OnBalancemoneyChanged();

        public virtual string Clinicdoctorid
        {
            get { return _clinicdoctorid; }
            set
            {
                OnClinicdoctoridChanging();
                _clinicdoctorid = value;
                OnClinicdoctoridChanged();
            }
        }
        partial void OnClinicdoctoridChanging();
        partial void OnClinicdoctoridChanged();

        public virtual string Introducer
        {
            get { return _introducer; }
            set
            {
                OnIntroducerChanging();
                _introducer = value;
                OnIntroducerChanged();
            }
        }
        partial void OnIntroducerChanging();
        partial void OnIntroducerChanged();

        public virtual decimal Afterabatemoeny
        {
            get { return _afterabatemoeny; }
            set
            {
                OnAfterabatemoenyChanging();
                _afterabatemoeny = value;
                OnAfterabatemoenyChanged();
            }
        }
        partial void OnAfterabatemoenyChanging();
        partial void OnAfterabatemoenyChanged();

        public virtual string Cautionerid
        {
            get { return _cautionerid; }
            set
            {
                OnCautioneridChanging();
                _cautionerid = value;
                OnCautioneridChanged();
            }
        }
        partial void OnCautioneridChanging();
        partial void OnCautioneridChanged();

        public virtual string Inhospurposeid
        {
            get { return _inhospurposeid; }
            set
            {
                OnInhospurposeidChanging();
                _inhospurposeid = value;
                OnInhospurposeidChanged();
            }
        }
        partial void OnInhospurposeidChanging();
        partial void OnInhospurposeidChanged();

        public virtual int Inhostimes
        {
            get { return _inhostimes; }
            set
            {
                OnInhostimesChanging();
                _inhostimes = value;
                OnInhostimesChanged();
            }
        }
        partial void OnInhostimesChanging();
        partial void OnInhostimesChanged();

        public virtual int Inhosstate
        {
            get { return _inhosstate; }
            set
            {
                OnInhosstateChanging();
                _inhosstate = value;
                OnInhosstateChanged();
            }
        }
        partial void OnInhosstateChanging();
        partial void OnInhosstateChanged();

        public virtual string Motherid
        {
            get { return _motherid; }
            set
            {
                OnMotheridChanging();
                _motherid = value;
                OnMotheridChanged();
            }
        }
        partial void OnMotheridChanging();
        partial void OnMotheridChanged();

        public virtual int Age
        {
            get { return _age; }
            set
            {
                OnAgeChanging();
                _age = value;
                OnAgeChanged();
            }
        }
        partial void OnAgeChanging();
        partial void OnAgeChanged();

        public virtual string Ageunit
        {
            get { return _ageunit; }
            set
            {
                OnAgeunitChanging();
                _ageunit = value;
                OnAgeunitChanged();
            }
        }
        partial void OnAgeunitChanging();
        partial void OnAgeunitChanged();

        public virtual string Enterhosoperatorid
        {
            get { return _enterhosoperatorid; }
            set
            {
                OnEnterhosoperatoridChanging();
                _enterhosoperatorid = value;
                OnEnterhosoperatoridChanged();
            }
        }
        partial void OnEnterhosoperatoridChanging();
        partial void OnEnterhosoperatoridChanged();

        public virtual string Leavehosdiagnoseid
        {
            get { return _leavehosdiagnoseid; }
            set
            {
                OnLeavehosdiagnoseidChanging();
                _leavehosdiagnoseid = value;
                OnLeavehosdiagnoseidChanged();
            }
        }
        partial void OnLeavehosdiagnoseidChanging();
        partial void OnLeavehosdiagnoseidChanged();

        public virtual string Leavehosmode
        {
            get { return _leavehosmode; }
            set
            {
                OnLeavehosmodeChanging();
                _leavehosmode = value;
                OnLeavehosmodeChanged();
            }
        }
        partial void OnLeavehosmodeChanging();
        partial void OnLeavehosmodeChanged();

        public virtual System.DateTime Enterhostransactdate
        {
            get { return _enterhostransactdate; }
            set
            {
                OnEnterhostransactdateChanging();
                _enterhostransactdate = value;
                OnEnterhostransactdateChanged();
            }
        }
        partial void OnEnterhostransactdateChanging();
        partial void OnEnterhostransactdateChanged();

        public virtual System.DateTime Leavehosdate
        {
            get { return _leavehosdate; }
            set
            {
                OnLeavehosdateChanging();
                _leavehosdate = value;
                OnLeavehosdateChanged();
            }
        }
        partial void OnLeavehosdateChanging();
        partial void OnLeavehosdateChanged();

        public virtual string Mark
        {
            get { return _mark; }
            set
            {
                OnMarkChanging();
                _mark = value;
                OnMarkChanged();
            }
        }
        partial void OnMarkChanging();
        partial void OnMarkChanged();

        public virtual int Inhosdays
        {
            get { return _inhosdays; }
            set
            {
                OnInhosdaysChanging();
                _inhosdays = value;
                OnInhosdaysChanged();
            }
        }
        partial void OnInhosdaysChanging();
        partial void OnInhosdaysChanged();

        public virtual string Leavehosoperatorid
        {
            get { return _leavehosoperatorid; }
            set
            {
                OnLeavehosoperatoridChanging();
                _leavehosoperatorid = value;
                OnLeavehosoperatoridChanged();
            }
        }
        partial void OnLeavehosoperatoridChanging();
        partial void OnLeavehosoperatoridChanged();

        public virtual System.DateTime Leavehostransactdate
        {
            get { return _leavehostransactdate; }
            set
            {
                OnLeavehostransactdateChanging();
                _leavehostransactdate = value;
                OnLeavehostransactdateChanged();
            }
        }
        partial void OnLeavehostransactdateChanging();
        partial void OnLeavehostransactdateChanged();

        public virtual string Tendlevel
        {
            get { return _tendlevel; }
            set
            {
                OnTendlevelChanging();
                _tendlevel = value;
                OnTendlevelChanged();
            }
        }
        partial void OnTendlevelChanging();
        partial void OnTendlevelChanged();


        

        #endregion
    }
}
